package com.chen.service;
/*
 *@description:描述
 *@author:陈琰
 *@time：2021/8/24  16:32
 */

import com.chen.dao.UserDao;
import com.chen.domain.LoginUser;
import com.chen.domain.RegeditUser;
import com.chen.domain.User;

//用户逻辑处理层
public class UserService {
    //登录
    public User login(LoginUser loginUser){
        return new UserDao().findUser(loginUser);
    }

    //注册
    public User regedit(RegeditUser regeditUser) {
        return new UserDao().findUserName(regeditUser);
    }

    //添加用户
    public User UserAdd(RegeditUser regeditUser) {
        UserDao userDao = new UserDao();
        User adduser = userDao.showAdd(regeditUser);
        return adduser;
    }



}
